<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<html>
<head>
    <title>${a.title}</title>
    <jsp:include page="commons/static.jsp" />
    <style>
        .article{
            padding: 15px 0;
        }

        .article .title{
            font-size: 24px;
            line-height: 30px;
        }

        .article .info{
            font-size: 12px;
            color: #999;
            margin-top: 20px;
        }

        .article .info span{
            margin-right: 20px;
        }

        .article .content{
            text-indent: 2em;
            font-size: 17px;
            letter-spacing: 1px;
            text-align: justify;
            margin-top: 30px;
        }
    </style>
</head>
<body>
<jsp:include page="commons/header.jsp" />

<div class="container">
    <div class="article">
        <h4 class="title">${a.title}</h4>

        <div class="info">
            <label for="">作者：</label>
            <span>${a.user.nickname}</span>

            <label for="">时间：</label>
            <span>
                    <fmt:formatDate value="${a.addTime}" pattern="yyyy-MM-dd HH:mm:ss" />
                </span>

            <label for="">阅读：</label>
            <span>${a.readTotal}</span>

            <c:if test="${ LOGIN_USER.id eq a.user.id }">
                <a href="/blog/article/edit?id=${a.id}">编辑</a>
                <a href="/blog/article/delete?id=${a.id}">删除</a>
            </c:if>

        </div>

        <div class="content">
            ${a.content}
        </div>
    </div>


</div>



</body>
</html>
